Manage a workspace with git

您所在的位置:网站首页 git no changes detected Manage a workspace with git

Manage a workspace with git

2023-05-31 21:10| 来源: 网络整理| 查看: 265

Manage a workspace with git Article 05/30/2023

This article walks you through the following basic tasks in Microsoft Fabric鈥檚 git integration tool:

Connect to a git repo Commit changes Update from git Disconnect from git

It鈥檚 recommended to read the overview of git integration before you begin.

Important

Microsoft Fabric is currently in PREVIEW. This information relates to a prerelease product that may be substantially modified before it's released. Microsoft makes no warranties, expressed or implied, with respect to the information provided here.

Prerequisites

To integrate git with your Microsoft Fabric workspace, you need to set up the following prerequisites in both Azure DevOps and Fabric.

Azure DevOps prerequisites An active Azure account registered to the same user that is using the Fabric workspace. Create a free account. Access to an existing repository Fabric prerequisites

To access the git integration feature, you need one of the following:

Premium license Access to a Fabric capacity workspace

In addition, your organization鈥檚 administrator has to enable the git integration switch. If git integration is disabled in the workspace, contact your administrator.

Connect a workspace to an Azure repo

Only a workspace admin can connect a workspace to an Azure Repo, but once connected, anyone with permission can work in the workspace. If you're not an admin, ask your admin for help with connecting. To connect a workspace to an Azure Repo, follow these steps:

Sign into Power BI and navigate to the workspace you want to connect with.

Go to Workspace settings

Note

If you don't see the Workspace settings icon, select the ellipsis (three dots) the then workspace settings.

Select Git integration. You鈥檙e automatically signed into the Azure Repos account registered to the Azure AD user signed into the workspace.

From the dropdown menu, specify the following details about the branch you want to connect to:

Note

You can only connect a workspace to one branch and folder at a time.

Organization Project Git repository Branch (Select an existing branch using the drop-down menu, or select + New Branch to create a new branch. You can only be connected to one branch at a time.) Folder (Select an existing folder in the branch or enter a name to create a new folder. If you don鈥檛 select a folder, content will be created in the root folder. You can only connect to one folder at a time.)

Select Connect and sync.

During the initial sync, if either the workspace or git branch is empty, content is copied from the nonempty location to the empty one. If both the workspace and git branch have content, you鈥檙e asked which direction the sync should go. For more information on this initial sync, see Connect and sync.

After you connect, the Workspace displays information about source control that allows the user to view the connected branch, the status of each item in the branch and the time of the last sync.

To keep your workspace synced with the git branch, commit any changes you make in the workspace to the git branch, and update your workspace whenever anyone creates new commits to the git branch.

Commit changes to git

Once you successfully connect to a git folder, edit your workspace as usual. Any changes you save are saved in the workspace only. When you鈥檙e ready, you can commit your changes to the git branch, or you can undo the changes and revert to the previous status. Read more about commits.

Commit to git Undo saved change

To commit your changes to the git branch, follow these steps:

Go to the workspace.

Select the Source control icon. This icon shows the number of uncommitted changes.

Select the Changes tab of the Source control pane. A list appears with all the items you changed, and an icon indicating if the item is new , modified , conflict , or deleted .

Select the items you want to commit. To select all items, check the top box.

Add a comment in the box. If you don't add a comment, a default message is added automatically.

Select Commit.

After the changes are committed, the items that were committed are removed from the list, and the workspace will point to the new commit that it's synced to.

After the commit is completed successfully, the status of the selected items changes from Uncommitted to Synced.

After you saved changes to the workspace, if you decide that you don鈥檛 want to commit those changes to git, you can undo the changes and revert those items to the previous (unsaved) status. To undo your changes, follow these steps:

Go to the workspace.

Select the Source control button. This button also shows the number of uncommitted changes.

Select the Changes tab of the Source control pane. A list appears with all the items you changed, and an icon indicating if the changed item is new , modified , conflict , or deleted .

Select the changes you want to undo.

Select Undo.

Select Undo again to confirm.

The selected items in your workspace revert to how they were when the workspace was last synced.

Important

If you delete an item and then undo the changes, the item is created anew and some of the metadata might be lost. For example, the sensitivity labels aren鈥檛 kept and should be reset, and the owner of the item is set to the current user.

Update workspace from git

Whenever anyone commits a new change to the connected git branch, a notification appears in the relevant workspace. Use the Source control pane to pull latest changes, merges or reverts into the workspace and update live items. Read more about updating.

To update a workspace, follow these steps:

Go to the workspace. Select the Source control icon. Select the Updates tab of the Source control pane. A list appears with all the items that were changed in the branch since the last update. Select Update all.

After it updates successfully, the list of items is removed, and the workspace will point to the new commit that it's synced to.

After the update is completed successfully, the status of the items changes to Synced.

Disconnect a workspace from git

Only a workspace admin can disconnect a workspace from an Azure Repo. If you鈥檙e not an admin, ask your admin for help with disconnecting. If you鈥檙e an admin and want to disconnect your repo, follow these steps:

Go to Workspace settings

Select Git integration

Select Disconnect workspace

Permissions

The actions you can take on a workspace depend on the permissions you have in both the workspace and Azure DevOps. For a more detailed discussion of permissions, see Permissions.

Considerations and limitations

If you're having trouble with these actions, make sure you understand the limitations of the git integration feature.

Next steps Understand the git integration process Manage git branches Git integration best practices


【本文地址】


今日新闻


推荐新闻


CopyRight 2018-2019 办公设备维修网 版权所有 豫ICP备15022753号-3